function HandlePMailerScoreSheetDetail(gui, user, date, options, data) {
  this._gui = gui;
  this._user = user;
  this._date = date;
  this._options = options;
  this._data = data;

  this._tasks = this._data['0'].data;
  this._popupBox = new ModulePopupBoxSimple();
  this._createElements();
};

HandlePMailerScoreSheetDetail.prototype._createElements = function() {
  var tr, td, _self = this;
  
  DOMUtils.removeTableRows(this._gui.main, 1);
  //*** Here ***
  if (this._tasks.length == 0) {
    tr = this._gui.main.insertRow(-1);
    td = tr.insertCell(-1);
    td.colSpan = 6;
    td.style.textAlign = 'left';
    td.style.height = '23px';
    td.appendChild(document.createTextNode('n/a'));
  }
  
  for (var i = 0, il = this._tasks.length; i < il; i++) {
    var task = this._tasks[i];
    tr = this._gui.main.insertRow(-1);
    tr.style.backgroundColor = (tr.rowIndex % 2 == 0) ? '#ececec' : '#fff';

    td = tr.insertCell(-1);
    td.style.borderRight = 'solid 1px #bbb';
    td.style.height = '23px';
    td.style.paddingLeft = '5px';
    td.style.textAlign = 'left';
    td.appendChild(document.createTextNode((task.customer_id != 0) ? PPublishUtils.customerId(task.customer_id) : '-'));

    td = tr.insertCell(-1);
    td.style.borderRight = 'solid 1px #bbb';
    td.style.height = '23px';
    td.style.paddingLeft = '5px';
    td.style.textAlign = 'left';
    td.appendChild(document.createTextNode((task.wedding_date != 0) ? SimpleDate.format(SimpleDate.fromStamp(task.wedding_date)) : '-'));
    
    td = tr.insertCell(-1);
    td.style.borderRight = 'solid 1px #bbb';
    td.style.height = '23px';
    td.style.paddingLeft = '5px';
    td.style.textAlign = 'left';
    td.appendChild(document.createTextNode(task.score));

    td = tr.insertCell(-1);
    td.style.borderRight = 'solid 1px #bbb';
    td.style.height = '23px';
    td.style.paddingLeft = '5px';
    td.style.textAlign = 'left';
    if (task.score_detail && task.score_detail.length > 30) {
      td.appendChild(document.createTextNode(task.score_detail.substring(0, 30)));
      var a = document.createElement('a');
      a.href = '#';
      a.appendChild(document.createTextNode('...'));
      a._task = task;
      a.onclick = function() { var pos = DOMUtils.findPos(this);
                               var div = document.createElement('div');
                               func1 = function() { _self._popupBox._close(); };
                               div.appendChild(MiscUtils.span('\n' + this._task.score_detail));
                               MiscUtils.dialog(_self._popupBox, pos, div, func1, null);
                               return false;
                             };
      td.appendChild(a);
    } else {
      td.appendChild(document.createTextNode((task.score_detail) ? task.score_detail : '-'));
    }
    
    td = tr.insertCell(-1);
    td.style.borderRight = 'solid 1px #bbb';
    td.style.height = '23px';
    td.style.paddingLeft = '5px';
    td.style.textAlign = 'left';
    td.appendChild(document.createTextNode(((task.culture1 || task.culture2) ? task.culture1 + ((task.culture1 && task.culture2) ? ',' : '') + task.culture2 : '-')));
    
    td = tr.insertCell(-1);
    td.style.height = '23px';
    td.style.paddingLeft = '5px';
    td.style.textAlign = 'left';
    td.appendChild(document.createTextNode((task.is_admin_retouched == 1) ? 'Y' : 'N'));
  }
  
};